import { ElMessage } from 'element-plus'

export function CheckInput(mess, showmessage) {
    if (typeof mess === 'string') {
        mess = mess.trim();
    }

    if (typeof mess === 'string' && mess !== "") {
        return true;
    } else {
        ElMessage({
            message: showmessage?showmessage: "请输入内容",
            type: 'error',
        });
        return false;
    }
}